package com.fzq.web;

import com.fzq.dao.po.SensitiveUser;
import com.fzq.service.SensitiveUserService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

@Slf4j
@RestController
@RequestMapping("/sjtm")
public class DesensitizationController {
    @Autowired
    SensitiveUserService SensitiveUserService;

    /**
     * 返回所有用户数据
     * @return
     */
    @GetMapping("/getAllUser")
    public Map<String,Object> getAllUser(){
        Map<String, Object> map = new HashMap<>();
        List<SensitiveUser> allList = SensitiveUserService.getAllList();
        List<SensitiveUser> allList2 = SensitiveUserService.getList();
        List<SensitiveUser> allList3 = SensitiveUserService.getList2();
        map.put("allList",allList);
        map.put("allList2",allList2);
        map.put("allList3",allList3);
        return map;
    }


}
